﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Lab.aspx.cs" Inherits="WebUI.LabManage.Lab" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
    <ext:PageManager ID="PageManager1" runat="server" AutoSizePanelID="Panel1" />
    <ext:Panel runat="server" ID="Panel1" BodyPadding="5px" EnableBackgroundColor="true"
        ShowBorder="false" Layout="Anchor" ShowHeader="true" Title="实验室管理">
        <Items>
            <ext:Form ID="Form2" runat="server" Height="76px" EnableBackgroundColor="true" ShowHeader="false"
                ShowBorder="false" BodyPadding="10px" AutoWidth="true">
                <Toolbars>
                    <ext:Toolbar ID="Toolbar1" runat="server">
                        <Items>
                            <ext:Button runat="server" ID="bnSearch" Text="查询" Icon="Reload" Type="Submit" OnClick="bnSearch_Click">
                            </ext:Button>
                            <ext:ToolbarSeparator ID="ToolbarSep1" runat="server">
                            </ext:ToolbarSeparator>
                            <ext:Button runat="server" ID="bnReset" Text="重置" Icon="ArrowIn" OnClick="bnReset_Click">
                            </ext:Button>
                            <ext:ToolbarFill ID="ToolbarFill1" runat="server">
                            </ext:ToolbarFill>
                            <ext:Button runat="server" ID="bnNew" Text="新增" Icon="Add">
                            </ext:Button>
                        </Items>
                    </ext:Toolbar>
                </Toolbars>
                <Rows>
                    <ext:FormRow>
                        <Items>
                            <ext:TextBox runat="server" ID="tb_labname" Label="实验室名">
                            </ext:TextBox>
                            <ext:DropDownList runat="server" ID="dl_location" Label="地理位置">
                            </ext:DropDownList>
                            <ext:DropDownList runat="server" ID="dl_level" Label="级别">
                            </ext:DropDownList>
                            <ext:DropDownList runat="server" ID="dl_category" Label="类别">
                            </ext:DropDownList>
                        </Items>
                    </ext:FormRow>
                </Rows>
            </ext:Form>
            <ext:Grid runat="server" ID="Grid1" AnchorValue="100% -80px" Title="实验室列表" ShowHeader="false"
                EnableBackgroundColor="true" EnableRowNumber="false" AllowPaging="true" OnPageIndexChange="Grid1_PageIndexChange"
                DataKeyNames="LabID" PageSize="25" AutoWidth="true" OnRowCommand="Grid1_RowCommand">
                <Columns>
                    <ext:BoundField DataField="LabNO" HeaderText="编号" />
                    <ext:BoundField Width="180px" DataField="LabName" HeaderText="实验室名" />
                    <ext:BoundField Width="100px" DataField="locationValue.value" HeaderText="地理位置" />
                    <ext:BoundField DataField="levelValue.value" HeaderText="级别" />
                    <ext:BoundField DataField="categoryValue.value" HeaderText="类型" />
                    <ext:BoundField DataField="area" HeaderText="面积" ToolTip="单位：平方米" />
                    <ext:BoundField DataField="useDate" DataFormatString="{0:yyyy}" HeaderText="启用年份" />
                    <ext:BoundField Width="120px" DataField="telephone" HeaderText="电话" />
                    <ext:CheckBoxField DataField="openStudent" HeaderText="对学生开放" />
                    <ext:CheckBoxField DataField="openTeacher" HeaderText="对老师开放" />
                    <ext:WindowField ColumnID="Editwindow" WindowID="window" Icon="TableEdit" ToolTip="修改实验室信息"
                        HeaderText="编辑" DataIFrameUrlFields="LabID" DataIFrameUrlFormatString="LabEdit.aspx?action=edit&id={0}"
                        DataWindowTitleField="LabName" DataWindowTitleFormatString="编辑- 实验室 - {0}" />
                    <ext:LinkButtonField Icon="TableDelete" HeaderText="删除" ToolTip="删除" ConfirmText="确认删除？" CommandName="Del" />
                </Columns>
            </ext:Grid>
        </Items>
    </ext:Panel>
    <ext:Window runat="server" ID="window" Popup="false" EnableIFrame="true" Title="实验室管理"
        IFrameUrl="about:blank" Target="Top" IsModal="true" Width="800px" Height="250px"
        EnableAjaxLoading="true">
    </ext:Window>
    </form>
</body>
</html>
